package com.lhd.action.iterator;

/**
 * @Author: liuhd
 * @Date: 2024/12/19 13:25
 * @Description: 具体聚合角色
 */
public class ConcreteBookCollection extends BookCollection {

    @Override
    void add(Book book) {
        bookList.add(book);
    }

    @Override
    BookIterator createIterator() {
        return new ConcreteBookIterator(bookList);
    }
}
